public class ThreadDemo13 {
    public static void main(String[] args) {
        Thread t1=new Thread() {
            @Override
            public void run() {
                System.out.println(Thread.currentThread().getId());
                System.out.println(this.getId());
            }
        };

        t1.start();

        Thread t2=new Thread(new Runnable() {
            @Override
            public void run() {
                System.out.println(Thread.currentThread().getId());
                //System.out.println(this.getId);   this 指向的是Runnable 实例，而不是Thread实例
            }
        });
    }
}
